package com.fay.convert.license;

import com.aspose.words.License;
import lombok.extern.slf4j.Slf4j;

import java.io.InputStream;

/**
 * aspose-words授权处理
 *
 * @author fay
 * @date 2021-06-03
 */
@Slf4j
public class MatchLicense {

    public static void init() {
        try (InputStream is = MatchLicense.class.getResourceAsStream("/license/license.xml")) {
            log.info("实现aspose-words授权去掉头部水印");
            License license = new License();
            license.setLicense(is);
        } catch (Exception e) {
            log.error("aspose-words授权失败", e);
        }
    }
}
